package pl.streamsoft.test.currency_buisness;

/**
 * Hello world!
 *
 */

import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.Calendar;
import java.util.GregorianCalendar;

import javax.xml.bind.JAXBException;

public class App {

	public static void main(String[] args) {

		try {
			NBPApi api = new NBPApi();
			api.initialize();
			Calendar calendar = new GregorianCalendar(2013,05,13);

			TabelaKursow tabela = api.getCurrencyTable(calendar);
			
			System.out.println(tabela.getPozycja().size());
			
		} catch (JAXBException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (FileNotFoundException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
		

	}
}
